package com.netflix.feign;

import com.netflix.dto.UserDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

/**
 * @author ytj
 * @date 2021/12/16
 */
@FeignClient(name = "demo-provider")
public interface DemoProviderFeign {
    @GetMapping("/get_demo")
    UserDTO getDemo(@RequestParam UserDTO userDTO);

    @GetMapping("/get_demo")
    UserDTO getDemo(@RequestParam String id,@RequestParam String name);

    @GetMapping("/get_demo")
    UserDTO getDemo(@RequestParam Map<String,Object> param);

    @PostMapping("/post_demo")
    UserDTO postDemo(@RequestBody UserDTO userDTO);


}
